<?phpclass TypesAddForm extends CFormModel{    public $name;    public $type;    public $remark;    public function rules()	{		return array(			array('name,type', 'required'),			array('remark', 'safe'),        );	}	//字段标签	public function attributeLabels()    {		return array(            'name' => "体系名称",            'type' => "类型",            'remark' => "备注",		);	}    /**     * @return bool     */	public function add()	{	    $goods = new actType();        $goods->name = $this->name;        $goods->type = $this->type;        $goods->remark = $this->remark;        $goods->create_time = date("Y-m-d G:i:s");        $goods->update_time = date("Y-m-d G:i:s");        $goods->del_flag = 0;        if ($goods->save()){            return true;        }else{            return false;        }	}	}